#ifndef XMLPARSE_H
#define XMLPARSE_H

#include <QtXml>
#include <QXmlDefaultHandler>

class XMLParse : public QXmlDefaultHandler
{

public:

XMLParse(QString spr_name);
~XMLParse();
QList< QMap<int, QString> > return_data();
bool startElement( const QString & ns,
                   const QString & localName,
                   const QString & qName,
                   const QXmlAttributes & attributes );
bool endElement( const QString & ns,
                 const QString & localName,
                 const QString & qName );
bool characters( const QString & str );
bool fatalError( const QXmlParseException & exception );
QString errorString() const;

private:

QString errorStr;
QString currentText;
bool metatag;
QList< QMap<int, QString> > d;
QMap<int, QString> m;
int elements;
QString spreadsheet;
bool selected_sheet;

};

#endif // XMLPARSE_H
